<?php
require_once "../db/db.php";
// TextboxList Autocomplete sample data for queryRemote: false (names are fetched all at once when TextboxList is initialized)

// get names (eg: database)
// the format is: 
// id, searchable plain text, html (for the textboxlist item, if empty the plain is used), html (for the autocomplete dropdown)

$response = array();
$query_select_group = "SELECT `id`, `name` From `oGroups`";
$result = DbSelect($query_select_group);

foreach ($result as $values)
{
	
	$response[] = array($values['id'], $values['name'], null, null);
	
}


header('Content-type: application/json');
echo json_encode($response);